package com.uwlaser.socket.client;

import lombok.Data;

import java.util.concurrent.ConcurrentHashMap;

/**
 * @Author QZK
 * @Description TODO
 * @Date 2022-12-05-14:50
 * @Version 1.0
 */
@Data
public class SocketConnectMap {

    private static final ConcurrentHashMap<String,BaseNettyMVBoxClient> CONNECT_MAP = new ConcurrentHashMap<>();

    public static void put(String name, BaseNettyMVBoxClient client){
        CONNECT_MAP.put(name, client);
    }

    public static BaseNettyMVBoxClient get(String name){
        return CONNECT_MAP.get(name);
    }

    public static boolean contains(String name){
        return CONNECT_MAP.containsKey(name);
    }
}
